﻿using Microsoft.AspNetCore.Authorization;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc;
using Asp.Versioning;

namespace Ebusiness_HttpApi
{
    /// <summary>
    /// 一级权限
    /// </summary>
    [Authorize("OrderMange")]
    [ControllerName("OrderTest")]
    [Route("api/[controller]/[action]")]
    public class OrderTestController : AbpController
    {
        public OrderTestController()
        {

        }

        /// <summary>
        /// 二级级权限
        /// </summary>
        /// <returns></returns>
        [Authorize("order_insert")]
        [HttpGet]
        public async Task<string> TestOne()
        {
            return "xxx";
        }

        /// <summary>
        /// 
        /// </summary>
        /// <returns></returns>
        [AllowAnonymous]
        [HttpGet]
        public async Task<string> TestTwo()
        {
            return "www";
        }
    }
}
